package com.ruoyi.overtime.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.overtime.mapper.HrOvertimeApplicationMapper;
import com.ruoyi.overtime.domain.HrOvertimeApplication;
import com.ruoyi.overtime.service.IHrOvertimeApplicationService;

/**
 * 加班申请Service业务层处理
 * 
 * @author gy
 * @date 2025-05-20
 */
@Service
public class HrOvertimeApplicationServiceImpl implements IHrOvertimeApplicationService 
{
    @Autowired
    private HrOvertimeApplicationMapper hrOvertimeApplicationMapper;

    /**
     * 查询加班申请
     * 
     * @param id 加班申请主键
     * @return 加班申请
     */
    @Override
    public HrOvertimeApplication selectHrOvertimeApplicationById(Long id)
    {
        return hrOvertimeApplicationMapper.selectHrOvertimeApplicationById(id);
    }

    /**
     * 查询加班申请列表
     * 
     * @param hrOvertimeApplication 加班申请
     * @return 加班申请
     */
    @Override
    public List<HrOvertimeApplication> selectHrOvertimeApplicationList(HrOvertimeApplication hrOvertimeApplication)
    {
        return hrOvertimeApplicationMapper.selectHrOvertimeApplicationList(hrOvertimeApplication);
    }

    /**
     * 新增加班申请
     * 
     * @param hrOvertimeApplication 加班申请
     * @return 结果
     */
    @Override
    public int insertHrOvertimeApplication(HrOvertimeApplication hrOvertimeApplication)
    {
        return hrOvertimeApplicationMapper.insertHrOvertimeApplication(hrOvertimeApplication);
    }

    /**
     * 修改加班申请
     * 
     * @param hrOvertimeApplication 加班申请
     * @return 结果
     */
    @Override
    public int updateHrOvertimeApplication(HrOvertimeApplication hrOvertimeApplication)
    {
        return hrOvertimeApplicationMapper.updateHrOvertimeApplication(hrOvertimeApplication);
    }

    /**
     * 批量删除加班申请
     * 
     * @param ids 需要删除的加班申请主键
     * @return 结果
     */
    @Override
    public int deleteHrOvertimeApplicationByIds(Long[] ids)
    {
        return hrOvertimeApplicationMapper.deleteHrOvertimeApplicationByIds(ids);
    }

    /**
     * 删除加班申请信息
     * 
     * @param id 加班申请主键
     * @return 结果
     */
    @Override
    public int deleteHrOvertimeApplicationById(Long id)
    {
        return hrOvertimeApplicationMapper.deleteHrOvertimeApplicationById(id);
    }
}
